cmake_minimum_required(VERSION 3.1)

set(PROJECT_NAME VsCmakeDemo)
project(${PROJECT_NAME})

set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

# 设置包的搜索路径
set(CMAKE_PREFIX_PATH G:/Qt/5.12.5/mingw73_32)
find_package(Qt5 COMPONENTS Widgets REQUIRED)

add_executable(${PROJECT_NAME} WIN32 ./src/main.cpp)

target_link_libraries(${PROJECT_NAME} Qt5::Widgets)
